import request from "@/utils/request";

// 分页查询申请列表（使用 POST /application/list）
export const _getApplicationList = (queryDto) => request.post('/api/application/list', queryDto)

// 根据id删除申请（路径参数）
export const _deleteApplication = (id) => request.delete(`/api/application/delete/${id}`)

// 根据id获取申请详情（路径参数）
export const _getApplicationById = (id) => request.get(`/api/application/getById/${id}`)

// 更新申请
export const _updateApplication = (application) => request.put('/api/application/update', application)

// 新增申请
export const _saveApplication = (application) => request.post('/api/application/save', application)

// 获取待我审核的申请列表
export const _getMyApplication = (queryDto) => request.post('/api/application/myApplication', queryDto)

// 审核通过
export const _passApplication = (applicationResultDto) => request.post('/api/application/pass', applicationResultDto)

// 审核拒绝
export const _rejectApplication = (applicationResultDto) => request.post('/api/application/rejected', applicationResultDto)

// 提交审核
export const _submitApplication = (ids) => request.post('/api/application/submit', ids)

// 根据用户ID获取学生相关信息
export const _getStudentByUserId = (id) => request.get(`/api/student/getByUserId/${id}`)

